package com.ranjiaqi.homework.managersystem;

import java.util.Objects;

/**
 * @ClassName Custom
 * @Description TODO
 * @Author hp
 * @Date 2021/6/25 18:15
 * @Version 1.0
 **/
public class Custom {
    private String name;
    private String gender;
    private Integer age;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getGender() {
        return gender;
    }


    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Custom custom = (Custom) o;
        return Objects.equals(name, custom.name) &&
                Objects.equals(gender, custom.gender) &&
                Objects.equals(age, custom.age);
    }

    @Override
    public int hashCode() {
        return Objects.hash(name, gender, age);
    }

    public void setGender(String gender) {

        this.gender = gender;
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    public Custom() {
    }

    public Custom(String name, String gender, Integer age) {
        this.name = name;
        this.gender = gender;
        this.age = age;
    }

    @Override
    public String toString() {
        return "Custom{" +
                "name='" + name + '\'' +
                ", gendet='" + gender + '\'' +
                ", age=" + age +
                '}';
    }
}
